<template>
  <PageContaier>
    <template #header>
      <DynamicForm :label-width="80" @onFinish="onFinish" :items="items" @search="search" v-model="formData" />
    </template>

    <template #content>
      <el-table>
        <el-table-column label="标题"></el-table-column>
        <el-table-column label="消息类型"></el-table-column>
        <el-table-column label="发布人"></el-table-column>
        <el-table-column label="发布时间"></el-table-column>
        <el-table-column label="优先级"></el-table-column>
        <el-table-column label="阅读状态"></el-table-column>
        <el-table-column label="操作"></el-table-column>
      </el-table>
    </template>
  </PageContaier>
</template>

<script lang="ts" setup>
import PageContaier from '@/components/PageContainer/index.vue'
import DynamicForm from '@/components/DynamicForm/index.vue'

const items = computed(() => {
  return [
    { prop: 'name', label: '标题', valueType: 'input' },
    { prop: 'user', label: '发布人', valueType: 'input' },
  ]
})

const formData = ref({})

const search = (data) => {

}

const onFinish = data => {
    console.log('onFinish', data);

}

</script>
